package com.ruoyi.system.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 商品管理对象 youxuan_goods
 * 
 * @author ruoyi
 * @date 2020-12-27
 */
@Data
public class YouxuanGoods extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** id */
    private Long id;

    /** 商品名称 */
    @Excel(name = "商品名称")
    private String name;

    /** 商品标题 */
    @Excel(name = "商品标题")
    private String tiltle;

    /** 商品编号 */
    @Excel(name = "商品编号")
    private Long productNum;

    /** 商品图片 */
    private String[] productImg;

    private String productImgString;

    private Integer category;//类别id
    /** 类别名称 */
    @Excel(name = "类别名称")
    private String categoryName;



    /** 是否上架，0：下架；1：上架 */
    @Excel(name = "是否上架，0：下架；1：上架")
    private Integer status;

    /** 品牌 */
    @Excel(name = "品牌")
    private String brand;

    /** 库存 */
    @Excel(name = "库存")
    private Integer stock;


    /** 秒杀总数量 */
    @Excel(name = "秒杀总数量")
    private Integer secKillTotal ;

    /** 可秒杀库存 */
    @Excel(name = "可秒杀库存")
    private Integer secKillStock ;

    /** 规格 */
    @Excel(name = "规格")
    private String specifications;

    /** 基础价格 */
    @Excel(name = "基础价格")
    private BigDecimal basePrice;

    /** 标注价格 */
    @Excel(name = "标注价格")
    private BigDecimal bidPrice;


    /** 保质期 */
    @Excel(name = "保质期")
    private String shelfLife;

    /** 储存方式 */
    @Excel(name = "储存方式")
    private Integer storageType;

    /** 商品新增日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "商品新增日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date gmtCreate;

    /** 商品修改日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "商品修改日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date gmtUpdate;

    /** 商品详情 */
    @Excel(name = "商品详情")
    private String productDetail;



    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("name", getName())
            .append("tiltle", getTiltle())
            .append("productNum", getProductNum())
            .append("productImg", getProductImg())
            .append("status", getStatus())
            .append("brand", getBrand())
            .append("specifications", getSpecifications())
            .append("basePrice", getBasePrice())
            .append("shelfLife", getShelfLife())
            .append("storageType", getStorageType())
            .append("gmtCreate", getGmtCreate())
            .append("gmtUpdate", getGmtUpdate())
            .append("productDetail", getProductDetail())
            .toString();
    }
}
